package com.tz.crm.service;

import com.tz.crm.entity.Payment;

import java.util.List;

/**
 * PaymentService 接口
 * 付款计划的查询保存
 */
public interface PaymentService extends BaseService<Payment, String> {

    /**
     * 保存付款计划
     *
     * @param payments   Payment List
     * @param contractId contract Id
     */
    void savePayment(List<Payment> payments, String contractId);

    /**
     * 根据合同的Id查询付款计划
     *
     * @param id Contract Id
     * @return Payment列表
     */
    List<Payment> getByContractId(String id);

    /**
     * 到款查询组合查询
     *
     * @param payment Payment查询信息
     * @return Payment列表
     */
    List<Payment> search(Payment payment);

}
